// @FileName  :example1c.c
// @Time      :2024/3/1 9:14
// @Author    :YKW
//# include <bits/stdc++.h>
//using namespace std;
# include <stdio.h>
# include <stdlib.h>
# include <math.h>
# include <string.h>
# include <stdlib.h>


void main() {
    long long res = 0;
    long long nowX = 1, flag = 0, op = 0;
    while (1) {
        long long n;
        char c;
        if (flag == 0) {
            scanf("%lld", &n);
            if (op == 0)nowX = n;
            else if (op == 1)nowX = -n;
            else if (op == 2)nowX *= n;
            else if (op == 3)nowX /= n;
            flag = 1;
        } else {
            scanf(" %c", &c);
            if (c == '+')res += nowX, op = 0;
            else if (c == '-')res += nowX, op = 1;
            else if (c == '*')op = 2;
            else if (c == '/')op = 3;
            else if (c == '=')break;
            flag = 0;
        }
    }
    res += nowX;
    printf("%lld", res);
    return 0;
}